<?php
Doo::loadCore('db/DooModel');

class FrbFlatChambreBase extends DooModel
{

    /**
     * @var int Max length is 11.
     */
    public $cha_id;

    /**
     * @var varchar Max length is 45.
     */
    public $cha_num;

    /**
     * @var float
     */
    public $cha_loy_low;

    /**
     * @var float
     */
    public $cha_loy_high;

    /**
     * @var float
     */
    public $cha_surf;

    /**
     * @var text
     */
    public $cha_det;

    /**
     * @var int Max length is 11.
     */
    public $imm_fid;

    public $_table = 'frbFlat_chambre';
    public $_primarykey = 'cha_id';
    public $_fields = array('cha_id','cha_num','cha_loy_low','cha_loy_high','cha_surf','cha_det','imm_fid');

    public function getVRules() {
        return array(
                'cha_id' => array(
                        array( 'integer' ),
                        array( 'maxlength', 11 ),
                        array( 'optional' ),
                ),

                'cha_num' => array(
                        array( 'maxlength', 45 ),
                        array( 'notnull' ),
                ),

                'cha_loy_low' => array(
                        array( 'float' ),
                        array( 'optional' ),
                ),

                'cha_loy_high' => array(
                        array( 'float' ),
                        array( 'notnull' ),
                ),

                'cha_surf' => array(
                        array( 'float' ),
                        array( 'optional' ),
                ),

                'cha_det' => array(
                        array( 'optional' ),
                ),

                'imm_fid' => array(
                        array( 'integer' ),
                        array( 'maxlength', 11 ),
                        array( 'notnull' ),
                )
            );
    }

}